package com.entity;

import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.math.BigDecimal;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 订单信息表 实体类。
 *
 * @author admin
 * @since 2025-11-21
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table("orders")
public class Orders implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 订单唯一标识，自增主键
     */
    @Id(keyType = KeyType.Auto)
    private Integer id;

    /**
     * 关联用户 ID，表明该订单属于哪个用户
     */
    private Integer userId;

    /**
     * 订单日期和时间，记录订单创建的时间
     */
    private String orderDate;

    /**
     * 订单总金额，精确到小数点后两位
     */
    private BigDecimal totalAmount;

    /**
     * 订单状态
     */
    private String status;

}
